//
//  BiDocumentsIndexViewController.m
//  TrunkIndustryManageSystem
//
//  Created by 李璐西 on 15/5/4.
//  Copyright (c) 2015年 李璐西. All rights reserved.
//

#import "BiDocumentsIndexViewController.h"
#import "BiDocListViewController.h"

@interface BiDocumentsIndexViewController ()

@end

@implementation BiDocumentsIndexViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    NSArray * imageStrArr = @[@"common/icon_xinxiao",@"common/icon_liebiao",@"common/icon_liebiao"];
            
    NSArray * titleArr = @[@"开缴款单审核",@"牌照信息上传",@"牌照信息审批"];
    
    
    [self refreshTable:titleArr imageArr:imageStrArr title:self.title];
}

#pragma -mark UitabeViewDelegate
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
    
    
    [tableView deselectRowAtIndexPath:indexPath animated:YES];
    
    UITableViewCell * cell = [tableView cellForRowAtIndexPath:indexPath];
    
    UILabel * tltlelab = (UILabel *)[cell viewWithTag:2];
    
    BiDocListViewController  * viewCtrl = [[BiDocListViewController alloc] init];
    
    if (tltlelab.text.hash == @"开缴款单审核".hash) {
        
        viewCtrl.type = 2;
    }
    else  if (tltlelab.text.hash == @"牌照信息上传".hash) {
        
        viewCtrl.type = 4;
    }
    else  if (tltlelab.text.hash == @"牌照信息审批".hash) {
        
        viewCtrl.type = 5;
    }
    
    viewCtrl.licenseType = self.licenseType;
    [self.navigationController pushViewController:viewCtrl animated:YES];
    
}

@end
